/*
 * tengine version 1.0
 * Copyright (C) 2011, Felix Bytow
 *
 * This file is part of tengine.
 *
 * tengine is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * tengine is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with tengine.  If not, see <http://www.gnu.org/licenses/>.
 */

#include "socket-api.hxx"

#if TENGINE_PLATFORM == TENGINE_PLATFORM_WINDOWS

#define WIN32_LEAN_AND_MEAN
#include <windows.h>
#include <winsock2.h>

tengine::Sockets::SocketApi(void)
{
	WSADATA wsa;
	WSAStartup(MAKEWORD(2, 2), &wsa);
}

tengine::Sockets::~SocketApi(void)
{
	WSACleanup();
}

#endif // TENGINE_PLATFORM == TENGINE_PLATFORM_WINDOWS
